﻿using System.Collections.Generic;
using Moq;
using Soundteller.AudioVisual.Services;
using Soundteller.AudioVisual.Services.Interfaces;
using Soundteller.Common.Tests;
using Soundteller.Visual.Model;
using Soundteller.Visual.Repositories.Interfaces;
using Soundteller.Visual.Services.Interfaces;

namespace Soundteller.AudioVisual.Tests.Unit.Services.SoundtellerDrawerSpecifications
{
    public abstract class SoundtellerDrawerTestBase : TestBase
    {
        protected ISoundtellerDrawer SoundtellerDrawer { get; private set; }
        protected Mock<IDrawer> Drawer { get; private set; }
        protected Mock<IGraphicRepository> GraphicRepository { get; private set; }

        protected override void Arrange()
        {
            Drawer = new Mock<IDrawer>();

            GraphicRepository = new Mock<IGraphicRepository>();
            GraphicRepository.Setup(r => r.GetByCategory(It.IsAny<string>())).Returns(new List<GraphicBase>());

            SoundtellerDrawer = new SoundtellerDrawer(Drawer.Object, GraphicRepository.Object);
        }

        protected override void Act()
        {
            SoundtellerDrawer.Draw();
        }
    }
}
